package com.ly.pojo.dto;

import lombok.Data;
import jakarta.validation.constraints.NotNull;
import java.net.URL;
import jakarta.validation.constraints.NotBlank;
import io.swagger.v3.oas.annotations.media.Schema;

/**
 * 新闻资讯信息封装
 *
 * @author Administrator
 * @date 2025-03-07 10:51:13
 */
@Data
public class NewsDTO {

    /**
     * 新闻ID
     */
    @NotNull(groups = { UpdateGroup.class, DeleteGroup.class }, message = "新闻ID不能为空")
    @Schema(description = "新闻ID")
    private Integer newsId;

    /**
     * 标题
     */
    @NotBlank(groups = { CreateGroup.class, UpdateGroup.class }, message = "标题不能为空")
    @Schema(description = "标题")
    private String title;

    /**
     * 内容
     */
    @Schema(description = "内容")
    private String content;

    /**
     * 图片URL
     */
    @Schema(description = "图片URL")
    private String imageUrl;
}
